package Model.Player;

import java.util.ArrayList;

import Model.Visible.Planet;
import Utils.ConstantsImplement;
import View.GUI.FleetGUI;

public class Player implements ConstantsImplement{
	
	private String name;
	private String net_addr;
	private ArrayList<Planet> planets_ = new ArrayList<Planet>();
	private int numPlanets = 0;
	private int race_; //0 para nyan, 1 para nayn
	
	public Player(Planet planet){
		addPlanet(planet);
	}
	
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getNet_addr() {
		return net_addr;
	}
	public void setNet_addr(String netAddr) {
		net_addr = netAddr;
	}
	
	public void setRace(int race){
		race_ = race;
	}

	public int getRace_() {
		return race_;
	}
	
	public void addPlanet(Planet planet){
		planets_.add(planet);
		numPlanets++;
		System.out.println("NUMPLANETS:"+race_+numPlanets);
	}
	
	public void removePlanet(Planet planet){
		planets_.remove(planet);
		numPlanets--;
		System.out.println("NUMPLANETS:"+race_+numPlanets);
	}
	
	public int getNumPlanets() {
		return numPlanets;
	}
}
